<template>
  <el-form ref="relationInfoForm" :model="info" :rules="rules" label-width="150px">
    <el-row>

      <el-col :span="12">
        <el-form-item prop="scriptTable">
          <span slot="label">
            脚本名称
            <el-tooltip content="生成表数据的脚本名" placement="top">
              <i class="el-icon-question"></i>
            </el-tooltip>
          </span>
          <el-input v-model="info.scriptTable" />
        </el-form-item>
      </el-col>

      <el-col :span="12">
        <el-form-item prop="scriptParamNum">
          <span slot="label">
            参数数量
            <el-tooltip content="脚本中的入参数量" placement="top">
              <i class="el-icon-question"></i>
            </el-tooltip>
          </span>
          <el-input v-model="info.scriptParamNum" />
        </el-form-item>
      </el-col>

      <el-col :span="24">
        <el-form-item prop="sqlScript" min-width="80%">
          <span slot="label">
            sql脚本
            <el-tooltip content="sql脚本语句" placement="top">
              <i class="el-icon-question"></i>
            </el-tooltip>
          </span>
          <el-input type="textarea"  :autosize="{ minRows: 15, maxRows: 20}" v-model="info.sqlScript" />
        </el-form-item>
      </el-col>

    </el-row>

  </el-form>
</template>
<script>
import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";

export default {
  name: "RelationInfoForm",
  components: { Treeselect },
  props: {
    info: {
      type: Object,
      default: null
    },
    menus: {
      type: Array,
      default: []
    },
  },
  data() {
    return {
      rules: {

      }
    };
  },
  created() {},
  methods: {
    /** 转换菜单数据结构 */
    /*normalizer(node) {
      if (node.children && !node.children.length) {
        delete node.children;
      }
      return {
        id: node.menuId,
        label: node.menuName,
        children: node.children
      };
    }*/
  }
};
</script>
